#include <iostream>
using namespace std;
#include"concrete_component.h"
#include"concrete_decorator.h"
#ifndef SAFE_DELETE
#define SAFE_DELETE(p) { if(p) {delete(p); (p) = nullptr;} }
#endif
int main()
{

    IBeverage *beverage=new HouseBlend();
    cout<<beverage->Name()<<":  "<<beverage->Cost()<<endl;
    IDecorator *decorator=new DecoratorA(beverage);
    cout<<decorator->Name()<<":  "<<decorator->Cost()<<endl;
    IDecorator *decorator1=new DecoratorB(decorator);
    cout<<decorator1->Name()<<":  "<<decorator1->Cost()<<endl;
    IDecorator *decorator2=new DecoratorC(decorator1);
    cout<<decorator2->Name()<<":  "<<decorator2->Cost()<<endl;


    return 0;
}


